package router

import (
	"github.com/gin-gonic/gin"
	"seat-service/api"
)

var classroomApi api.ClassroomApi

type ClassroomRouter struct {
}

func (*ClassroomRouter) classroomGroup(router *gin.RouterGroup) {
	classroom := router.Group("classroom")
	{
		classroom.GET("all", classroomApi.GetAll)                                 // 查询所有教室信息
		classroom.GET("getByStatue", classroomApi.GetReserveByClassroomStatue)    // 根据教室状态查询教室信息
		classroom.GET("getByBuilding", classroomApi.GetByBuildingID)              //TODO  根据教学楼id查询所有教室信息
		classroom.POST("seat", classroomApi.GetSeatByIdAndStartEndTime)           // TODO 通过教室id,开始时间，结束时间获取可预约座位信息
		classroom.POST("freeSeat", classroomApi.GetFreeSeatByStartTime)           // TODO 通过时间获取所有教室这个时间段的可用座位
		classroom.POST("getByBuildingAndName", classroomApi.GetByBuildingAndName) // 通过 3 A01 模糊查询教室信息
	}
}
